package com.iedu.demo.lgq.mapper;

import com.iedu.demo.lgq.entity.Kuaidi100Delivery;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.apache.ibatis.annotations.Select;

import java.util.List;

@Mapper
public interface TbKuaidi100DeliveryMapper {
    // 获取所有快递公司
    @Select("SELECT * FROM kuaidi100_delivery")
    List<Kuaidi100Delivery> findAllDeliveryCompanies();



    // 根据快递公司ID获取名称
    @Select("SELECT delivery_name FROM kuaidi100_delivery WHERE id = #{deliveryId}")
    String findDeliveryNameById(long deliveryId);

    TbKuaidi100DeliveryMapper findDeliveryById(@Param("deliveryed") long deliveryId);
}
